#include <bits/stdc++.h>
using namespace std;
int main() {

  int n, m, c; 
  cin >> n >> m >> c;
  int hang=c/m;
  int lie=c%m;
  if(lie==0){
    cout << hang << " " << m << endl;
  }
  else{
    cout << hang+1 << " " << lie << endl;
  }



  return 0;
}